<div layout-padding>
    <md-content >
        <div layout="column">
            <md-card ng-repeat="question in questions track by $index" ng-click="cardClick($index)" layout="row" title="选择此题">
                <md-card-title>
                    <md-checkbox title="选择此题" aria-label="Checkbox" ng-model="selected[$index]"
                                 ng-click="cardClick($index)" ng-disabled = "expire">
                    </md-checkbox>
                    <md-card-title-text>
                        <span class="md-headline">{{question.name}}</span>
                        <div ng-repeat="extra in question.extras">
                            {{extra}}
                        </div>
                    </md-card-title-text>
                </md-card-title>
            </md-card>

        </div>
    </md-content>
</div>

<div layout-padding>
    <md-content layout="column">
        <md-input-container>
            <label>试题名称</label>
            <input required ng-model="newQuizTitle">
        </md-input-container>
        <!--<md-input-container>-->
            <!--<label>开始时间</label>-->
            <!--<input type="datetime-local" name="date" placeholder="yyyy-MM-ddTHH:mm:ss" min="2017-01-01T00:00:00" max="2030-12-31T00:00:00" required ng-model="date" id="user_date"/>-->
        <!--</md-input-container>-->

        <md-input-container layout = "row" >
            <md-input-container class="md-block" flex-gt-sm >
                <label>年份</label>
                <md-select ng-model="startDate.year" ng-disabled = "expire">
                    <md-option ng-repeat="year in startYear" value="{{year}}">
                        {{year}}
                    </md-option>
                </md-select>
            </md-input-container>
            <md-input-container class="md-block" flex-gt-sm >
                <label>月份</label>
                <md-select ng-model="startDate.month" ng-disabled = "expire">
                    <md-option ng-repeat="month in startMonth" value="{{month}}">
                        {{month}}
                    </md-option>
                </md-select>
            </md-input-container>
            <md-input-container class="md-block" flex-gt-sm >
                <label>日期</label>
                <md-select ng-model="startDate.day" ng-disabled = "expire">
                    <md-option ng-repeat="day in startDay" value="{{day}}">
                        {{day}}
                    </md-option>
                </md-select>
            </md-input-container>
            <md-input-container class="md-block" flex-gt-sm >
                <label>小时</label>
                <md-select ng-model="startDate.hour" ng-disabled = "expire">
                    <md-option ng-repeat="hour in startHour" value="{{hour}}">
                        {{hour}}
                    </md-option>
                </md-select>
            </md-input-container>
            <md-input-container class="md-block" flex-gt-sm >
                <label>分钟</label>
                <md-select ng-model="startDate.minute" ng-disabled = "expire">
                    <md-option ng-repeat="minute in startMinute" value="{{minute}}">
                        {{minute}}
                    </md-option>
                </md-select>
            </md-input-container>
        </md-input-container>

        <md-input-container>
            <label>持续时间(分钟）</label>
            <input required ng-model="minute">
        </md-input-container>

        <md-button ng-click="submit(newQuizTitle)" class="md-raised md-primary" flex="none">确定</md-button>
    </md-content>
    <!--<md-content flex-gt-xs>-->
        <!--<label>Enter date</label>-->
        <!--<md-datepicker ng-model="user.submissionDate"></md-datepicker>-->
    <!--</md-content>-->
    <!--<label for="meeting">约会日期：</label><input id="meeting" type="date" value="2014-01-13:23-55"/>-->
</div>
<div ng-show="false">
    {{questionSet}}
</div>
<style>
    md-list {
        padding: 2em;
    }

    md-checkbox {
    }
</style>